Element Properties

Element Properties

Every element (control, dialog, widget, ...) has properties that you can set and get.

  • attribute : static visual properties
  • callback : dynamic action properties

To explore everything there is to know about IupButton() start with this small program:

include iupw.e 
IupOpen() 
 
atom btn = IupButton( "hello") 
atom dlg = IupDialog( btn ) 
 
IupShow(dlg) 
 
IupMainLoop() 
IupClose() 

What you see is a plain, inactive button in a dialog.

To realize what is possible run this program:

include iupw.e 
IupOpen() 
 
atom btn = IupButton( "hello") 
atom dlg = IupDialog( btn ) 
 
IupShow(dlg) 
 
atom prop = IupElementPropertiesDialog(dlg, btn ) 
 
IupPopup( prop, IUP_CURRENT, IUP_CURRENT) 
IupMainLoop() 
IupClose() 

A popup dialog appears that lists all attributes and callbacks associated with the Button element.

You can even change attribute values in the popup dialog and see how they change the Button.

Not Categorized, Please Help

Search



Quick Links

User menu

Not signed in.

Misc Menu